package com.tanhua.dubbo.api;

import com.tanhua.model.enums.CommentType;
import com.tanhua.model.mongo.Comment;

import java.util.List;

public interface CommentApi {

    /*
    * 发布评论并获取评论数量
    * */
    Integer save(Comment comment);

    /*
    * 分页查询
    * */
    List<Comment> findComments(String movementId, CommentType commentType, Integer page, Integer pagesize);

    /*
    * 判断是否点赞
    * */
    Boolean hasComment(String movementId, Long userId, CommentType commentType);

    /*
    * 取消点赞
    * */
    Integer delete(Comment comment);

    /*
    * 评论点赞
    * */
    Integer saveLikeComment(Comment comment);

    /*
    * 取消点赞评论
    * */
    Integer deleteLikeComment(Comment comment);
}